import { createStore, applyMiddleware } from "../redux";
import combineReducer from "./reducers";
import logger from "./logger";
import promise from "./promise";
import thunk from "./thunk";
let initialState = { counter1: { number: 10 }, counter2: { number: 20 } };

// let store = createStore(combineReducer);
// let store = applyMiddleware(logger, thunk, promise)(createStore)(
//   combineReducer,
//   initialState
// );
let store = createStore(
  combineReducer,
  initialState,
  applyMiddleware(thunk, promise, logger)
);

export default store;
